/**
 * jims
 */
package com.jims.master.modules.sync.service;

import com.jims.master.common.persistence.Page;
import com.jims.master.common.service.CrudService;
import com.jims.master.modules.sync.dao.LabDao;
import com.jims.master.modules.sync.entity.Lab;
import com.jims.master.modules.sync.entity.LabApply;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import java.util.List;

/**
 * 检验记录主表Service
 * @author ct
 * @version 2017-11-20
 */
@Service
@Transactional(readOnly = true)
public class LabService extends CrudService<LabDao, Lab> {

	@Override
    public Lab get(String id) {
		return super.get(id);
	}
	
	@Override
    public List<Lab> findList(Lab lab) {
		return super.findList(lab);
	}
	
	@Override
    public Page<Lab> findPage(Page<Lab> page, Lab lab) {
		return super.findPage(page, lab);
	}
	
	@Override
    @Transactional(readOnly = false)
	public int save(Lab lab) {
		return super.save(lab);
	}
	
	@Override
    @Transactional(readOnly = false)
	public int delete(Lab lab) {
		return super.delete(lab);
	}

	public List<Lab> getLab(Lab lab){
		return dao.getLab(lab);
	}

	public List<Lab> getLabByVisitId(String visitId){
		return dao.getLabByVisitId(visitId);
	}
	/**
	 * 健康轴查看检验申请
	 * @param clinicId
	 * @Author WangYQ
	 * @return
	 */
	public List<Lab> getLabApply(String clinicId) {
		return dao.getLabApply(clinicId);
	}
}